home *** CD-ROM | disk | FTP | other *** search
- /* @(#) IconSuite.h 6/19/92
- {Sources}Hack:IconSuite.h
-
- No rights reserved
-
- Product: Joel’s MacHack ’92 entry
- File: IconSuite.h
- Author: Joel West, Palomar Software
- Date: Fri, Jun 19, 1992
- Description: This represents System 7 Finder icon plotting routines
- that is documented in Tech Note #306 (May 1992)
- that should be in an MPW header file, but is not
- */
-
- #ifndef __ICONSUITE__
- #define __ICONSUITE__
-
- #include <Types.h>
- #include <QuickDraw.h>
- #include <Icons.h>
-
- enum {
- Large1BitMask = 'ICN#',
- Large4BitData = 'icl4',
- Large8BitData = 'icl8',
- Small1BitMask = 'ics#',
- Small4BitData = 'ics4',
- Small8BitData = 'ics8',
- Mini1BitMask = 'sicn',
- Mini4BitData = 'icm4',
- Mini8BitData = 'icm8'
- };
-
- enum {
- ttNone = 0x0,
- ttDisabled = 0x1,
- ttOffline = 0x2,
- ttOpen = 0x3,
- ttSelected = 0x4000,
- ttSelectedDisabled = (0x4000 + 0x1),
- ttSelectedOffline = (0x4000 + 0x2),
- ttSelectedOpen = (0x4000 + 0x3),
- ttLabel0 = 0x0000,
- ttLabel1 = 0x0100,
- ttLabel2 = 0x0200,
- ttLabel3 = 0x0300,
- ttLabel4 = 0x0400,
- ttLabel5 = 0x0500,
- ttLabel6 = 0x0600,
- ttLabel7 = 0x0700
- } IconTransformType;
-
- enum {
- atNone = 0x0,
- atVerticalCenter = 0x1,
- atTop = 0x2,
- atBottom = 0x3,
- atHorizontalCenter = 0x4,
- atLeft = 0x8,
- atRight = 0xC
- };
-
- pascal OSErr PlotIconID(const Rect *theRect, short align, short transform, short theResID)
- = {0x303C, 0x0500, 0xABC9};
- pascal OSErr NewIconSuite(Handle *theIconSuite) = {0x303C, 0x0207, 0xABC9};
- pascal OSErr AddIconToSuite(Handle theIconData,Handle theSuite,ResType theType)= {0x303C, 0x0608, 0xABC9};
- pascal OSErr GetIconFromSuite(Handle *theIconData,Handle theSuite,ResType theType)= {0x303C, 0x0609, 0xABC9};
- pascal OSErr ForEachIconDo(Handle theSuite,short selector,ProcPtr action,void *yourDataPtr)
- = {0x303C, 0x080A, 0xABC9};
- pascal OSErr GetIconSuite(Handle *theIconSuite,short theResID,short selector)= {0x303C, 0x0501, 0xABC9};
- pascal OSErr DisposeIconSuite(Handle theIconSuite,Boolean disposeData)= {0x303C, 0x0302, 0xABC9};
- pascal OSErr PlotIconSuite(const Rect *theRect,short align,short transform,Handle theIconSuite)
- = {0x303C, 0x0603, 0xABC9};
- pascal OSErr MakeIconCache(Handle *theHandle,ProcPtr makeIcon,void *yourDataPtr)= {0x303C, 0x0604, 0xABC9};
- pascal OSErr LoadIconCache(const Rect *theRect,short align,short transform,Handle theIconCache)
- = {0x303C, 0x0606, 0xABC9};
- pascal OSErr GetLabel(short labelNumber,RGBColor *labelColor,Str255 labelString)= {0x303c, 0x050B, 0xABC9};
- pascal Boolean PtInIconID(Point testPt,Rect *iconRect,short alignment,short iconID)= {0x303c, 0x060D, 0xABC9};
- pascal Boolean PtInIconSuite(Point testPt,Rect *iconRect,short alignment,Handle theIconSuite)
- = {0x303c, 0x070E, 0xABC9};
- pascal Boolean RectInIconID(Rect *testRect,Rect *iconRect,short alignment,short iconID)
- = {0x303c, 0x0610, 0xABC9};
- pascal Boolean RectInIconSuite(Rect *testRect,Rect *iconRect,short alignment,Handle theIconSuite)
- = {0x303c, 0x0711, 0xABC9};
- pascal OSErr IconIDToRgn(RgnHandle theRgn,Rect *iconRect,short alignment,short iconID)
- = {0x303c, 0x0613, 0xABC9};
- pascal OSErr IconSuiteToRgn(RgnHandle theRgn,Rect *iconRect,short alignment,Handle theIconSuite)
- = {0x303c, 0x0714, 0xABC9};
- pascal OSErr SetSuiteLabel(Handle theSuite, short theLabel)= {0x303C, 0x0316, 0xABC9};
- pascal short GetSuiteLabel(Handle theSuite)= {0x303C, 0x0217, 0xABC9};
- pascal OSErr GetIconCacheData(Handle theCache, void **theData)= {0x303C, 0x0419, 0xABC9};
- pascal OSErr SetIconCacheData(Handle theCache, void *theData)= {0x303C, 0x041A, 0xABC9};
- pascal OSErr GetIconCacheProc(Handle theCache, ProcPtr *theProc)= {0x303C, 0x041B, 0xABC9};
- pascal OSErr SetIconCacheProc(Handle theCache, ProcPtr theProc)= {0x303C, 0x041C, 0xABC9};
- pascal OSErr PlotSICNHandle(const Rect *theRect,short align,short transform,Handle theSICN)
- = {0x303C, 0x061E, 0xABC9};
- pascal OSErr PlotCIconHandle(const Rect *theRect,short align,short transform,CIconHandle theCIcon)
- = {0x303C, 0x061F, 0xABC9};
- pascal OSErr SetLabel(short labelNumber, const RGBColor *, ConstStr255Param)
- = {0x303C, 0x050C, 0xABC9};
-
- #endif __ICONSUITE__
-